<script src="/javascripts/comment.js" type="text/javascript"></script>
<div id="form" class='form'>
  <% form_for @comment do |f| %><%= f.error_messages %><% end %>

  <h3>提交评论</h3>
  <textarea id="comment_content" rows="3" cols="25"></textarea>
  <input type="hidden" id="comment_product_id"  value="<%=params[:product_id] %>" />
  <input type="hidden" id="comment_user_id"  value="<%=session[:user_id] %>" />
  <p>
    <button onclick="addComment();">添加评论</button>
  </p>

</div>